[PATCH] hurd: SCM_CREDS support
authorGNU Libc Maintainers <debian-glibc@lists.debian.org>
Sun, 1 Mar 2026 20:10:06 +0000 (21:10 +0100)
committerAurelien Jarno <aurel32@debian.org>
Sun, 1 Mar 2026 20:10:06 +0000 (21:10 +0100)
commit8115b99eabbb3ab3e7edc38c8856fe12f3459bc9
tree7eef2c0e97046c656d912039a3bfbb1e27ef1dd0
parent63fd65b2831916dc0dc9e0391b7dc9c8814ba68e
[PATCH] hurd: SCM_CREDS support

Svante Signell  <svante.signell@gmail.com>
Samuel Thibault  <samuel.thibault@ens-lyon.org>

* sysdeps/mach/hurd/sendmsg.c (__libc_sendmsg): On SCM_CREDS
control messages, record uids, pass a rendez-vous port in the
control message, and call __auth_user_authenticate_request to
make auth send credentials on that port.  Do not wait for a
reply.
* sysdeps/mach/hurd/recvmsg.c (contains_uid, contains_gid,
check_auth): New functions.
(__libc_recvmsg): On SCM_CREDS control messages, call check_auth
to check the passed credentials thanks to the answer from the
auth server.
* hurd/Makefile (user-interfaces): Add auth_request and
auth_reply.

FIXME: this doesn't actually check uid/gid.

Gbp-Pq: Topic hurd-i386
Gbp-Pq: Name tg-sendmsg-SCM_CREDS.diff
hurd/Makefile
sysdeps/mach/hurd/recvmsg.c
sysdeps/mach/hurd/sendmsg.c